// Copyright 2022 a.o.smith ALL Rights Reserved
package com.liuxinlong.enums;

/**
 * 流程与系统业务类型枚举
 *
 * @author liuxinlong@hotwater.com.cn
 * @version 1.0.0
 * @since 2023-02-17
 */
public enum ButlerProcessTypeEnum {
    ALL(0, "全部"),
    SYSTEM(1, "系统"),
    PROCESS(2, "流程"),
    OTHER(3, "其他");

    private int value;

    private String name;

    ButlerProcessTypeEnum(int value, String name) {
        this.value = value;
        this.name = name;
    }

    public int getValue() {
        return value;
    }

    public String getName() {
        return name;
    }

    public static String getNameByValue(int value) {
        ButlerProcessTypeEnum arrObj[] = ButlerProcessTypeEnum.values();
        for (ButlerProcessTypeEnum obj : arrObj) {
            if (value == obj.getValue()) {
                return obj.getName();
            }
        }
        return " ";
    }

}
